home *** CD-ROM | disk | FTP | other *** search
/ Loadstar 18 / 018.d81 / text reader (.txt) < prev    next >
Commodore BASIC  |  2022-08-26  |  3KB  |  95 lines

  1. 0 rem contents map reader
  2. 1 ifpeek(51201)<>12orpeek(51202)<>200thenload"routines v4",8,1
  3. 2 d$=chr$(96):forx=1to6:d$=d$+d$:next
  4. 3 open15,8,15
  5. 4 poke650,255
  6. 5 da$=" --------------------------------------"
  7. 6 li=52016:su=51206:sd=51209:cl=51203
  8. 7 forc=217to242:pokel,peek(l)or128:next
  9. 8 print"[147][154]";:poke53281,0:poke53282,9
  10. 9 poke1020,4:poke1021,21:poke1022,1:poke1023,38
  11. 10 sys52176:fi=usr(65535)
  12. 11 iffi=11thenfi$="contents map.t"
  13. 12 iffi=12thenfi$="t.cat tool boot"
  14. 13 iffi=13thenfi$="math reflect"
  15. 14 iffi=14thenfi$="comp.eyes.review"
  16. 20 dm=500:dimin$(dm)
  17. 30 gosub5000:remopening blurb
  18. 40 gosub6000:remload file
  19. 45 print"[147]";:goto50
  20. 46 print"[176]";left$(d$,38);"[174]";
  21. 47 fori=1to18:print"[221]                                      [221]";:next
  22. 48 print"[173]";left$(d$,38);"[189]";:print"";:forl=217to242:pokel,128orpeek(l):next
  23. 49 return
  24. 50 gosub7000:gosub46:print"";:
  25. 800 print:forc1=0to16:print""in$(c1):next:print""in$(c1);:lp=0
  26. 810 poke646,1:syscl:print"";
  27. 850 getk$:print"[158]";:ifk$=""then850
  28. 860 ifk$="[145]"ork$=""ork$="[134]"ork$="[138]"thengosub11000:goto850
  29. 865 ifk$="[137]"ork$="[133]"thenforcc=1to18:gosub11000:next:goto850
  30. 870 ifk$=""ork$="[157]"ork$="[139]"ork$="[135]"thengosub10000:goto850
  31. 875 ifk$="[136]"ork$="[140]"thenforcc=1to18:gosub10000:next:goto850
  32. 877 ifk$="p"thengosub2000:print"[147]":goto50
  33. 878 ifk$="x"ork$="[216]"then63000
  34. 879 ifk$="\"ork$="[169]"thengosub12000:         goto850
  35. 880 print"[158]";:gosub7000:print"[146][154]";:gosub7000:goto850
  36. 1000 :
  37. 2000 rem hard(NULL)
  38. 2010 print""da$:print"[212]urn on your printer and press[160]<return>"
  39. 2011 getk$:ifk$=""then2011
  40. 2012 ifk$<>chr$(13)then2090
  41. 2015 print"---------------------------------------"
  42. 2020 print"";
  43. 2030 open4,4,7:print#4,chr$(17);
  44. 2040 lp=0:page=0
  45. 2050 for pp=0toll
  46. 2052 print#4,in$(pp):page=page+1
  47. 2054 ifpage=60thenprint#4,"":page=0
  48. 2056 next pp:print#4:close4
  49. 2090 return
  50. 3000 rem  print lines
  51. 3010 print#4,in$(i);spc(40-len(in$(i)));in$(i+rs)
  52. 3020 return
  53. 5000 print""da$:print"         --[204]oading some text--"
  54. 5010 print" ----------[208]lease be patient.----------"
  55. 5045 print:print:print"[208]ress 'x' to exit now without reading"
  56. 5050 print:print"this article."
  57. 5060 return
  58. 6000 open8,8,8,fi$
  59. 6030 ll=0:poke781,8:sys65478
  60. 6040 sysli,b$:in$(ll)=mid$(b$,1)
  61. 6044 ifpeek(198)<>0thenifpeek(631)=88then6100
  62. 6045 ifst=0thenll=ll+1:goto6040
  63. 6100 sys65484:close8:close15
  64. 6105 lc=ll:nl=ll
  65. 6110 return
  66. 6150 sys65484:close8:close15
  67. 7000 print" -----[208]ress f1-f7 keys to move text----"
  68. 7005 print" -------[208]ress 'p' to print text.-------"
  69. 7010 print" ----------[208]ress 'x' to exit-----------"
  70. 7015 printda$
  71. 7020 return
  72. 10000 poke646,1:syscl:print"";:              iflp>=lc-15then10015
  73. 10002 print"";:        lp=lp+1:syssu
  74. 10005 ifleft$(in$(lp+17),4)="\oad"then        print"":goto10020
  75. 10010 printin$(lp+17):goto10020
  76. 10015 poke53280,rnd(1)*15
  77. 10020 return
  78. 10030 :
  79. 11000 poke646,1:syscl:print"";:              iflp<=1then11015
  80. 11002 print"";:lp=lp-1:syssd
  81. 11005 ifleft$(in$(lp),4)="\oad"then           print"":goto10020
  82. 11010 printin$(lp):goto11020
  83. 11015 poke53280,rnd(1)*15
  84. 11020 return
  85. 12000 rem   can you run it now?
  86. 12010 forx=lptolp+15:ifleft$(in$(x),4)=       "\oad"then13000
  87. 12020 next:return
  88. 13000 rem    yes, you can run it now!
  89. 13010 print"[147]l"mid$(in$(x),2):             print"run"
  90. 13020 goto63020
  91. 63000 poke650,128:f$="hello"
  92. 63005 iffi=14thenf$="comp.eyes.menu"
  93. 63010 print"[147]load"chr$(34)f$chr$(34)       ",8":print"run"
  94. 63020 poke631,13:poke632,13:poke198,2:        end
  95.